/**********************************************************************************************************************
* COPYRIGHT 
* ------------------------------------------------------------------------------------------------------------------- 
* Copyright (c) iSOFT INFRASTRUCTURE SOFTWARE CO., LTD. This software is proprietary to 
* iSOFT INFRASTRUCTURE SOFTWARE CO., LTD., and all rights are reserved by iSOFT INFRASTRUCTURE SOFTWARE CO., LTD. 
* Without the express written permission of the company, no organization or individual may copy, install, trial, 
* distribute, or reverse engineer this software. For terms of use and further details, please refer to the End User 
* License Agreement (EULA) or contact us business@i-soft.com.cn for more assistance. 
* 
* This file contains code from EasyXMen, which is licensed under the LGPL-2.1. However, due to a special exception, 
* you are not required to comply with the provisions of section 6a of LGPL-2.1. Specifically, you may distribute 
* your software, including this file, under terms of your choice, including proprietary licenses, without needing to 
* provide the source code or object code as specified in section 6a. For more details, please refer to the project's 
* LICENSE and EXCEPTION files and the specific exception statement.  
* ------------------------------------------------------------------------------------------------------------------- 
* FILE DESCRIPTION 
* ------------------------------------------------------------------------------------------------------------------- 
*  @MCU                : S32K148 
*  @file               : CanIf_Cfg.c 
*  @license            : Evaliation 
*  @licenseExpiryDate  :  
*  @date               : 2024-10-21 10:36:42 
*  @customer           : EasyXMen User 
*  @toolVersion        : 2.0.18 
*********************************************************************************************************************/ 
/*******************************************************************************
**                      Include Section                                       **
*******************************************************************************/
#include "CanIf.h"
#include "CanSM_Cbk.h"
#include "PduR_CanIf.h"
#include "CanTp_Cbk.h"
#include "CanTp.h"
#include "CanNm_Cbk.h"
#include "Can_43_FLEXCAN.h"

/*******************************************************************************
**                      Macros                                                **
*******************************************************************************/

/*******************************************************************************
**                      Global Data Types                                     **
*******************************************************************************/

/*******************************************************************************
**                      Global Symbols                                        **
*******************************************************************************/
#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
/* PRQA S 1531 ++ */ /* MISRA Rule 8.7 */
CONST(CanIf_DispatchConfigType,CANIF_CONST) CanIf_DispatchConfigData =
/* PRQA S 1531 -- */ /* MISRA Rule 8.7 */
{/* CanIfDispatchUserConfirmPnAvailabilityName */
    &CanSM_ControllerBusOff,/* CanIfDispatchUserCtrlBusOffName */
    &CanSM_ControllerModeIndication, /* CanIfDispatchUserCtrlModeIndicationName */

    NULL_PTR, /* CanIfDispatchUserTrcvModeIndicationName */
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
/* PRQA S 1531 ++ */ /* MISRA Rule 8.7 */
CONST(Can_DriverApiType,CANIF_CONST_PBCFG) Can_DriverApi[CANIF_CANDRIVER_NUMBER] =
/* PRQA S 1531 -- */ /* MISRA Rule 8.7 */
{
    {
        &Can_43_FLEXCAN_SetControllerMode,
        &Can_43_FLEXCAN_Write,
    },
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
CONST(CanIf_ControllerCfgType,CANIF_CONST) CanIf_CtrlCfgData[CANIF_CANCONTROLLER_NUMBER] =
{
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        CANIF_CAN_43_FLEXCAN,
        FALSE,
        0u,0u|0u,
    },
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
static CONST(PduIdType, CANIF_CONST) CanIf_HrhRxPduRef[] =
{
    CANIF_RXPDU_CAN0_Rx_0x251_Cyclic_PN29, /*CANIF_HOH0_HRH_0 */
    CANIF_RXPDU_CAN0_Rx_0x250_Cyclic_PN17, /*CANIF_HOH0_HRH_1 */
    CANIF_RXPDU_CAN0_Rx_0x200_Cyclic, /*CANIF_HOH0_HRH_2 */
    CANIF_RXPDU_CAN0_Rx_0x201_Event, /*CANIF_HOH0_HRH_3 */
    CANIF_RXPDU_CAN0_Rx_0x202_Mixed, /*CANIF_HOH0_HRH_4 */
    CANIF_RXPDU_CAN0_Rx_0x203_Cyclic_Counter, /*CANIF_HOH0_HRH_5 */
    CANIF_RXPDU_CAN0_Rx_0x708_Diag_Phy_Request, /*CANIF_HOH0_HRH_6 */
    CANIF_RXPDU_CAN0_Rx_0x7df_Diag_Fun_Request, /*CANIF_HOH0_HRH_7 */
    CANIF_RXPDU_CAN0_Rx_0x5xx_NM_ECU, /*CANIF_HOH0_HRH_8 */
    CANIF_RXPDU_CAN0_Rx_0x260_E2E_P01, /*CANIF_HOH0_HRH_9 */
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
static CONST(CanIfHrhCfgType,CANIF_CONST) CanIf_HrhCfgData[CANIF_HRH_NUMBER] =
{
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        5u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[0],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        4u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[1],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        0u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[2],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        1u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[3],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        2u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[4],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        3u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[5],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        9u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[6],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        10u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[7],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        11u,
        1u,
        CANIF_BASIC_CAN,
        &CanIf_HrhRxPduRef[8],

    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,

        6u,
        1u,
        CANIF_FULL_CAN,
        &CanIf_HrhRxPduRef[9],

    },
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
static CONST(CanIfHthCfgType,CANIF_CONST) CanIf_HthCfgData[CANIF_HTH_NUMBER] =
{
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        18u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        17u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        13u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        14u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        15u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        16u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        22u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        12u,
        CANIF_FULL_CAN,
    },
    {
        CANIF_CANDRV_0_CANIF_CTR_DRV_CanController_0,
        19u,
        CANIF_FULL_CAN,
    },
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
CanIfRxPduUserRxIndicationNameApiType CanIf_UpRxIndicationArray[CANIF_RXINDICATION_FUNC_NUMBER] =
{
        &PduR_CanIfRxIndication,
        &CanTp_RxIndication,
        &CanNm_RxIndication,
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
static CONST(CanIf_RxPduConfigType,CANIF_CONST) CanIf_RxPduConfigData[CANIF_RXPDU_NUMBER] =
{
    {
        /*0  CANIF_RXPDU_CAN0_Rx_0x251_Cyclic_PN29 */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_0,
        PDUR_SRCPDU_CAN0_Rx_0x251_Cyclic_PN29,

        8u,
        0x251u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*1  CANIF_RXPDU_CAN0_Rx_0x250_Cyclic_PN17 */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_1,
        PDUR_SRCPDU_CAN0_Rx_0x250_Cyclic_PN17,

        8u,
        0x250u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*2  CANIF_RXPDU_CAN0_Rx_0x200_Cyclic */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_2,
        PDUR_SRCPDU_CAN0_Rx_0x200_Cyclic,

        8u,
        0x200u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*3  CANIF_RXPDU_CAN0_Rx_0x201_Event */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_3,
        PDUR_SRCPDU_CAN0_Rx_0x201_Event,

        8u,
        0x201u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*4  CANIF_RXPDU_CAN0_Rx_0x202_Mixed */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_4,
        PDUR_SRCPDU_CAN0_Rx_0x202_Mixed,

        8u,
        0x202u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*5  CANIF_RXPDU_CAN0_Rx_0x203_Cyclic_Counter */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_5,
        PDUR_SRCPDU_CAN0_Rx_0x203_Cyclic_Counter,

        8u,
        0x203u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*6  CANIF_RXPDU_CAN0_Rx_0x708_Diag_Phy_Request */
        FALSE,
        FALSE,

        1,
        CANIF_HOH0_HRH_6,
        CANTP_CAN0_Rx_0x708_Diag_Phy_Request,

        8u,
        0x708u,
        0x7ffu,
        CANIF_RX_STANDARD_NO_FD_CAN,
},
    {
        /*7  CANIF_RXPDU_CAN0_Rx_0x7df_Diag_Fun_Request */
        FALSE,
        FALSE,

        1,
        CANIF_HOH0_HRH_7,
        CANTP_CAN0_Rx_0x7df_Diag_Fun_Request,

        8u,
        0x7dfu,
        0x7ffu,
        CANIF_RX_STANDARD_NO_FD_CAN,
},
    {
        /*8  CANIF_RXPDU_CAN0_Rx_0x5xx_NM_ECU */
        TRUE,
        FALSE,

        2,
        CANIF_HOH0_HRH_8,
        CanNmConf_CanNmRxPdu_CanNmRxPdu,

        8u,
        0x500u,
        0x700u,
        CANIF_RX_STANDARD_CAN,
},
    {
        /*9  CANIF_RXPDU_CAN0_Rx_0x260_E2E_P01 */
        FALSE,
        FALSE,

        0,
        CANIF_HOH0_HRH_9,
        PDUR_SRCPDU_CAN0_Rx_0x260_E2E_P01,

        8u,
        0x260u,
        0x7ffu,
        CANIF_RX_STANDARD_CAN,
},
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
CanIfTxPduUserTxConfirmationNameApiType CanIf_UpTxConfirmationArray[CANIF_TXCONFIRMATION_FUNC_NUMBER] =
{
        &CanTp_TxConfirmation,
        &CanNm_TxConfirmation,
        &PduR_CanIfTxConfirmation,
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
static CONST(CanIf_TxPduConfigType,CANIF_CONST) CanIf_TxPduConfigData[CANIF_TXPDU_NUMBER] =
{
    {
        /* 0  CANIF_TXPDU_CAN0_Tx_0x351_Cyclic_PN29 */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_0,
        PDUR_DESTPDU_CAN0_Tx_0x351_Cyclic_PN29,
        0xffffu,

        0xffffu,

        0x351u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 1  CANIF_TXPDU_CAN0_Tx_0x350_Cyclic_PN17 */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_1,
        PDUR_DESTPDU_CAN0_Tx_0x350_Cyclic_PN17,
        0xffffu,

        0xffffu,

        0x350u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 2  CANIF_TXPDU_CAN0_Tx_0x300_Cyclic */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_2,
        PDUR_DESTPDU_CAN0_Tx_0x300_Cyclic,
        0xffffu,

        0xffffu,

        0x300u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 3  CANIF_TXPDU_CAN0_Tx_0x301_Event */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_3,
        PDUR_DESTPDU_CAN0_Tx_0x301_Event,
        0xffffu,

        0xffffu,

        0x301u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 4  CANIF_TXPDU_CAN0_Tx_0x302_Mixed */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_4,
        PDUR_DESTPDU_CAN0_Tx_0x302_Mixed,
        0xffffu,

        0xffffu,

        0x302u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 5  CANIF_TXPDU_CAN0_Tx_0x303_Cyclic_Counter */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_5,
        PDUR_DESTPDU_CAN0_Tx_0x303_Cyclic_Counter,
        0xffffu,

        0xffffu,

        0x303u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 6  CANIF_TXPDU_CAN0_Tx_0x709_Diag_Phy_Response */

        FALSE,
        8u,

        0u,
        CANIF_HOH0_HTH_6,
        CANTP_CAN0_Tx_0x709_Diag_Phy_Response,
        0u,

        0xffffu,

        0x709u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 7  CANIF_TXPDU_CAN0_Tx_0x501_NM_ECU */

        FALSE,
        8u,

        1u,
        CANIF_HOH0_HTH_7,
        CanNmConf_CanNmTxPdu_CanNmTxPdu,
        0xffffu,

        0xffffu,

        0x501u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
    {
        /* 8  CANIF_TXPDU_CAN0_Tx_0x360_E2E_P01 */

        FALSE,
        8u,

        2u,
        CANIF_HOH0_HTH_8,
        PDUR_DESTPDU_CAN0_Tx_0x360_E2E_P01,
        0xffffu,

        0xffffu,

        0x360u,
        0x7ffu,
        CANIF_TX_STANDARD_CAN,
        CANID_STATIC,
    },
};
#define CANIF_STOP_SEC_CONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_VAR_NO_INIT_8
#include "CanIf_MemMap.h"
static uint8 TxPduBuffer[16];
#define CANIF_STOP_SEC_VAR_NO_INIT_8
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_VAR_INIT_UNSPECIFIED
#include "CanIf_MemMap.h"
static VAR(CanIf_TxPduBufferType, CANIF_VAR) CanIf_TxPduBuffer[] =
{
/* BUFFER_CAN0_Tx_0x709_Diag_Phy_Response, Length is 8, size is 2 */
    {
        FALSE,
        0u,
        0xffffu,
        0xffffffffu,
        &TxPduBuffer[0],
    },
    {
        FALSE,
        0u,
        0xffffu,
        0xffffffffu,
        &TxPduBuffer[8],
    },
};
#define CANIF_STOP_SEC_VAR_INIT_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_VAR_INIT_UNSPECIFIED
#include "CanIf_MemMap.h"
/* PRQA S 1531 ++ */ /* MISRA Rule 8.7 */
VAR(CanIf_TxBufferType, CANIF_VAR) CanIf_TxBuffer[CANIF_TXBUFFER_NUMBER] =
/* PRQA S 1531 -- */ /* MISRA Rule 8.7 */
{
    {&CanIf_TxPduBuffer[0]},
};
#define CANIF_STOP_SEC_VAR_INIT_UNSPECIFIED
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_CONFIG_DATA_8
#include "CanIf_MemMap.h"
static CONST(uint8,CANIF_CONST) CanIf_TxBufferSizeCfg[CANIF_TXBUFFER_NUMBER] ={2};
#define CANIF_STOP_SEC_CONFIG_DATA_8
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_PBCONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
/* PRQA S 1531 ++ */ /* MISRA Rule 8.7 */
CONST(CanIf_ConfigType,CANIF_CONST) CanIf_InitCfgSet =
/* PRQA S 1531 -- */ /* MISRA Rule 8.7 */
{
    CanIf_HrhCfgData,

    CanIf_HthCfgData,
   CanIf_RxPduConfigData,
    CanIf_TxPduConfigData,
    CanIf_TxBufferSizeCfg,
};
#define CANIF_STOP_SEC_PBCONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"

#if (STD_OFF == CANIF_RXINDICATION_AUTOSAR_PARAMETER)
#define CANIF_START_SEC_PBCONFIG_DATA_16
#include "CanIf_MemMap.h"
static CONST(uint16,CANIF_CONST_PBCFG) CanIf_Can0Hoh2HrhId[12u] =
{
    0x2u,0x3u,0x4u,0x5u,0x1u,0x0u,0x9u,0xFFFFu,0xFFFFu,0x6u,
    0x7u,0x8u,
};
#define CANIF_STOP_SEC_PBCONFIG_DATA_16
#include "CanIf_MemMap.h"

#define CANIF_START_SEC_PBCONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
/* PRQA S 1533 ++ */ /* MISRA Rule 8.9 */
CONST(CanIf_CanHOH2HRHType,CANIF_CONST) CanIf_CanHoh2Hrh[1] =
/* PRQA S 1533 -- */ /* MISRA Rule 8.9 */
{
    {
        CanIf_Can0Hoh2HrhId,
        12u,
    },
};
#define CANIF_STOP_SEC_PBCONFIG_DATA_UNSPECIFIED
#include "CanIf_MemMap.h"
#endif/*STD_OFF == CANIF_RXINDICATION_AUTOSAR_PARAMETER*/
/*******************************************************************************
**                      End of file                                           **
*******************************************************************************/
